/*
 * ProgressBar.h
 *
 *  Created on: May 5, 2012
 *      Author: gonzalo
 */

#ifndef PROGRESSBAR_H_
#define PROGRESSBAR_H_

#include "Label.h"
#include "SDL/SDL_gfxPrimitives.h"
#include "../../common/utils/UtilString.h"

#define PROGRESS_BARRA_WIDTH 50
#define PROGRESS_BARRA_HEIGHT 3

class ProgressBar: public Widget {
public:
	ProgressBar(int porcent, int posX, int posY, Widget* parent);
	virtual ~ProgressBar();

	virtual void showOn(SDL_Surface* surface);

	void resetBar(int porcent);
	int getPorcent();

	int reducePercent(int percent);
private:
	SDL_Surface* fillSurface;
	int porcent;


	void updatePorcent();
};

#endif /* PROGRESSBAR_H_ */
